<%@page import="cn.kgcnews.pojo.NewsDetail"%>
<%@page import="cn.kgcnews.service.impl.NewsServiceImpl"%>
<%@page import="cn.kgcnews.service.NewsService"%>
<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta charset="utf-8">
<!--声明文档兼容模式，表示使用IE浏览器的最新模式-->
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<!--设置视口的宽度(值为设备的理想宽度)，页面初始缩放值<理想宽度/可见宽度>-->
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- 上述3个meta标签*必须*放在最前面，任何其他内容都*必须*跟随其后！ -->
<title>新闻中国</title>

<!-- Bootstrap的样式文件-->
<link href="css/bootstrap.min.css" rel="stylesheet">
<link rel="shortcut icon" href="images/favicon.ico"
	mce_href="images/favicon.ico" type="image/x-icon">
<script type="text/javascript" src="js/jquery-1.12.4.js"></script>
</head>
<body>

	<!--导航栏-->
	<%@ include file="header.jsp"%>
	<!--轮播图-->
	<div class="container" style="margin-top:-15px">
		<div id="carousel-example-generic" class="carousel slide"
			data-ride="carousel">
			<!-- Indicators -->
			<ol class="carousel-indicators">
				<li data-target="#carousel-example-generic" data-slide-to="0"
					class="active"></li>
				<li data-target="#carousel-example-generic" data-slide-to="1"></li>
				<li data-target="#carousel-example-generic" data-slide-to="2"></li>
				<li data-target="#carousel-example-generic" data-slide-to="3"></li>
			</ol>

			<!-- Wrapper for slides -->
			<div class="carousel-inner" role="listbox">
				<div class="item active">
					<img src="images/banner.png" width="100%" alt="...">
				</div>
				<div class="item">
					<img src="images/banner.png" width="100%" alt="...">
				</div>
				<div class="item">
					<img src="images/banner.png" width="100%" alt="...">
				</div>
				<div class="item">
					<img src="images/banner.png" width="100%" alt="...">
				</div>
			</div>

			<!-- Controls -->
			<a class="left carousel-control" href="#carousel-example-generic"
				role="button" data-slide="prev"> <span
				class="glyphicon glyphicon-chevron-left" aria-hidden="true"></span>
				<span class="sr-only">Previous</span> </a> <a
				class="right carousel-control" href="#carousel-example-generic"
				role="button" data-slide="next"> <span
				class="glyphicon glyphicon-chevron-right" aria-hidden="true"></span>
				<span class="sr-only">Next</span> </a>
		</div>
	</div>
	<!--主体内容-->
	<div class="container" style="margin-top: 15px;">
		<div class="row">
			<div class="col-md-3" style="height: 630px;">
				<div class="list-group" style="margin-bottom:2px">
					<a href="#" class="list-group-item active"> 新闻主题 </a> <a href="#"
						class="list-group-item">国内<span class="badge">GO</span>
					</a> <a href="#" class="list-group-item">国际<span class="badge">GO</span>
					</a> <a href="#" class="list-group-item">天气<span class="badge">GO</span>
					</a> <a href="#" class="list-group-item">科技<span class="badge">GO</span>
					</a> <a href="#" class="list-group-item">娱乐<span class="badge">GO</span>
					</a> <a href="#" class="list-group-item">体育<span class="badge">GO</span>
					</a>
				</div>
				<div class="list-group">
					<a href="#" class="list-group-item active"> 国内新闻 </a> <a href="#"
						class="list-group-item">国内<span class="badge">GO</span>
					</a> <a href="#" class="list-group-item">国际<span class="badge">GO</span>
					</a> <a href="#" class="list-group-item">天气<span class="badge">GO</span>
					</a> <a href="#" class="list-group-item">科技<span class="badge">GO</span>
					</a> <a href="#" class="list-group-item">娱乐<span class="badge">GO</span>
					</a> <a href="#" class="list-group-item">体育<span class="badge">GO</span>
					</a> <a href="#" class="list-group-item">体育<span class="badge">GO</span>
					</a>
				</div>
			</div>
			<div class="col-md-6" style="height: 630px;">
				<div id="topnews" class="list-group" style="margin-left: -15px;">
					<a href="#" class="list-group-item active"> 新闻列表 </a>
					<!-- <script type="text/javascript">
							$.get("jsonnews",function(newslist){
				
							//var newslist=$.parseJSON(result);
							for(var i in newslist){
							$("#topnews").append("<a target=\"_blank\" href=\"newsReadServlet?newsid="+newslist[i].id+"&action=newsread\" class=\"list-group-item\">"+newslist[i].title+"<span class=\"badge\">GO</span></a>");
							} 
							//console.log(result);
							},"JSON");
				</script> -->
					<script type="text/javascript">
							$.getJSON("jsonnews",function(newslist){
				
							//var newslist=$.parseJSON(result);
							for(var i in newslist){
							$("#topnews").append("<a target=\"_blank\" href=\"newsReadServlet?newsid="+newslist[i].id+"&action=newsread\" class=\"list-group-item\">"+newslist[i].title+"<span class=\"badge\">GO</span></a>");
							} 
							//console.log(result);
							});
				</script>
						
            </div>
        </div>
        <div class="col-md-3" style="height: 630px;">
            <div class="panel panel-primary" style="margin-left: -15px;">
                <div class="panel-heading">
                    <h3 class="panel-title">最新活动</h3>
                </div>
                <div class="panel-body">
                    <dl class="text-center">
                        <dt><img src="images/new-1.png"/></dt>
                        <dd>PHP从入门到放弃</dd>
                    </dl>
                    <dl class="text-center">
                        <dt><img src="images/new-2.png"/></dt>
                        <dd>Java Web从绝望到希望</dd>
                    </dl>
                    <dl class="text-center">
                        <dt><img src="images/new-3.png"/></dt>
                        <dd>课工场五一回馈</dd>
                    </dl>
                    <dl class="text-center" style="padding-bottom: 15px">
                        <dt><img src="images/new-3.png"/></dt>
                        <dd>课工场五一回馈</dd>
                    </dl>
                </div>
            </div>
        </div>
    </div>
</div>
<!--通栏广告-->
<div class="container">
    <img src="images/wy.jpg" width="99.7%">
</div>
<%@ include file="footer.jsp" %><script src="js/jquery-1.12.4.js"></script>
					<!-- 加载 Bootstrap 的所有 JavaScript 插件。你也可以根据需要只加载单个插件。 -->
					<script src="js/bootstrap.min.js"></script>
</body>
</html>